var t = require;
var e = module;
var o = exports;
var n =
    (this && this.__extends) ||
    (function () {
        var t = function (e, o) {
            return (t =
                Object.setPrototypeOf ||
                ({__proto__: []} instanceof Array &&
                    function (t, e) {
                        t.__proto__ = e;
                    }) ||
                function (t, e) {
                    for (var o in e) e.hasOwnProperty(o) && (t[o] = e[o]);
                })(e, o);
        };
        return function (e, o) {
            function n() {
                this.constructor = e;
            }
            t(e, o), (e.prototype = null === o ? Object.create(o) : ((n.prototype = o.prototype), new n()));
        };
    })();
Object.defineProperty(o, "__esModule", {value: !0});
var r = t("fsm"),
    a = t("fightManager"),
    i = t("bodyAI"),
    s = t("bodyDie"),
    c = (function (t) {
        function e() {
            return (null !== t && t.apply(this, arguments)) || this;
        }
        return (
            n(e, t),
            (e.prototype.onEnter = function () {
                this.context.is_player()
                    ? r.changeState(this.context, s.default)
                    : ((this.context.box.enabled = !1),
                      this.context.sk.play("Die", !1, this, this.onAniEnd),
                      a.default.inst.enemy.remove(this.context, this.谁打死你自己 == a.default.inst.player));
            }),
            (e.prototype.onAniEnd = function () {
                this.context.node.destroy();
            }),
            (e.prototype.onMove = function () {}),
            (e.prototype.onMoveStop = function () {}),
            (e.prototype.on_skill = function () {}),
            e
        );
    })(i.default);
o.default = c;
